package ru.pashkan.spring;

import org.springframework.context.support.AbstractApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

import java.util.Date;

public class Main {

    public static void main(String[] args) {
        try {
            AbstractApplicationContext context = new ClassPathXmlApplicationContext("applicationContext.xml");
            context.registerShutdownHook();
            System.out.println("Application started at " + new Date());
        }
        catch(Throwable t) {
            System.out.println("Error at starting application: " + t);
        }
    }
}
